<template>
  <div v-if="showFlag && notice && notice!=''" class="special-show flex gui-padding pointer justify-center pr mainbgb cof" style="position:relative;z-index: 2000">
    <span class="ksd-resume-close" @click="handleClose"><i class="iconfont icon-shanchu4"></i></span>
    <div>{{notice}}</div>
  </div>
</template>
<script setup>
const userVipRef = ref({})
const showFlag = ref(true)
const userStore = useStore.userState()

defineProps({
  notice:{
    type:String,
    default:""
  }
})
const handleUserVipDialog = async ()=>{
  await useLoginDialog()
  userVipRef.value.handleOpen()
}
const handleClose =  ()=>{
  showFlag.value = false
  sessionStorage.setItem("ksd-special-markshow","hidden")
}

onMounted(() => {
    var flag = sessionStorage.getItem("ksd-special-markshow")
    if (flag && flag == 'hidden') {
      showFlag.value = false
    }
})

</script>
<style scoped>
.ksd-resume-close {
  position: absolute;
  right: 10px;
  top: 15px;
  z-index: 1000;
  cursor: pointer;
}
</style>